package ui;

import java.util.Locale;
import java.util.ResourceBundle;

public class Resources {
	private ResourceBundle resources;
	private static final Resources singleton = new Resources();
	
	private Resources () {
		Locale currentLocale = Locale.getDefault();

        resources = ResourceBundle.getBundle(
            "ui/resources/vmidi", currentLocale);
	}
	
	public static Resources getInstance () {
		return singleton;
	}
	
	/**
	 * Get a localized resource, given its key.
	 * @param key Resource key.
	 * @return the localized resource, if any.
	 */
	public String getString (final String key) {
		return resources.getString(key);
	}
}
